﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Text;

namespace ServiceDemo
{
    class Program
    {
        static void Main(string[] args)
        {
            //var planDate = DateTime.Now;
            //var startDate = new DateTime();
            //var endDate = new DateTime();
            //   new DateHelper().GetRangeThisWeek(planDate, out startDate, out endDate);

            //for (var i = startDate; i <= endDate; i = i.AddDays(1))
            //{
            //    Console.WriteLine(i);
            //}


            //List<Person> personList = new List<Person>();
            //personList.Add(new Person() { FirstName = "Mickey", LastName = "Mouse" });
            //personList.Add(new Person() { FirstName = "Mickey", LastName = "Mouse" });
            //personList.Add(new Person() { FirstName = "zhang", LastName = "san" });
            //string columnName = "FirstName";
            //        var dics = personList.GroupBy(x => GetPropertyValue(x, columnName)).ToDictionary(x => x.Key, x => x.Count());
            //foreach(var dic in dics)
            //{
            // Console.WriteLine(string.Format("{0},{1}\r\n", dic.Key, dic.Value));
            //}
            //Console.WriteLine("tttttttttttt");
            //Console.WriteLine("tttttttttttt");
            //Console.WriteLine("tttttttttttt");
            var t = 26 / 1110.0;
           
            Console.WriteLine(Math.Round(decimal.Parse((5 / (decimal)1110).ToString("00.000")), 4) * 100);

            Console.ReadKey();
        }
        //public object GetPropertyValue(Person view, string fieldName)
        //{
        //    //return view.GetType().GetPropertyValue(fieldName);
        //    //switch (view.GetType().GetPropertyValue(fieldName))
        //    //{

        //    //}
        //}
        //private static BindingFlags _bindingFlags { get; }
        //    = BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.Public | BindingFlags.Static;
        //public static object GetPropertyValue(this object obj, string propertyName)
        //{
        //    return obj.GetType().GetProperty(propertyName, _bindingFlags).GetValue(obj);
        //}
    }
    //public class Person
    //{
    //    public string FirstName { set; get; }
    //    public string LastName { set; get; }
    //    public Person() { }
    //    public Person(string firstName, string lastName)
    //    {
    //        FirstName = firstName;
    //        LastName = lastName;
    //    }
    //}
}
